using IStrong.EC.Abstractions.Interfaces;
using System;
using System.Collections.Generic;
using System.Text;

namespace IStrong.EC.WebApi.Results.Entity
{
    /// <summary> 
    /// 客户跟踪记录
    /// </summary> 
    public class CustomerOldRecord : IEntity
    {

        /// <summary> 
        /// ID
        /// </summary> 
        public int RowId { get; set; }
        /// <summary> 
        /// ID
        /// </summary> 
        public int Id { get; set; }
        
        /// <summary>
        /// 
        /// </summary>
        public string CustomerId { get; set; }
        
        /// <summary>
        /// 跟踪时间
        /// </summary>
        private DateTime _Tm { get; set; }
        /// <summary>
        /// 跟踪时间
        /// </summary>
        public string Tm
        {
            get
            {
                if (null != _Tm) return _Tm.ToString("yyyy-MM-dd HH:mm:ss");
                return string.Empty;
            }
            set
            {
                if (!string.IsNullOrWhiteSpace(value))
                    _Tm = DateTime.Parse(value);
            }
        }
        /// <summary>
        /// 跟踪人员
        /// </summary>
        public string TrackPepole { get; set; }
        /// <summary>
        /// 跟踪记录
        /// </summary>
        public string Content { get; set; }
        /// <summary>
        /// 跟踪对象
        /// </summary>
        public string Target { get; set; }

        /// <summary>
        /// 商机
        /// </summary>
        public string CommercialOpportunity { get; set; }

        /// <summary>
        /// 下一次跟进时间
        /// </summary>
        private DateTime _TmNext { get; set; }
        /// <summary>
        /// 下一次跟进时间
        /// </summary>
        public string TmNext
        {
            get
            {
                if (null != _TmNext) return _TmNext.ToString("yyyy-MM-dd");
                return string.Empty;
            }
            set
            {
                if (!string.IsNullOrWhiteSpace(value))
                    _TmNext = DateTime.Parse(value);
            }
        }
    }
}